import pandas as pd

filename = 'elmserver.xlsx'

sheet_names = list(range(1, 11))
for sheet_name in sheet_names:
    try:
        df = pd.read_excel(filename, sheet_name=f'{sheet_name}')
    except Exception as e:
        print(e)
        print(sheet_name)
        continue
    for v in df.values:
        mobile = str(v[0]).strip()
        device = str(v[1]).strip()
        # 如果是nan
        if any([mobile == 'nan', device == 'nan']):
            continue
        print(mobile[:11], device)
